﻿/**
 * IndexBuilder.java	1.0 2007 五月 29 14:29:49,创建
 */

package org.in4j.search.index;

import java.util.ArrayList;
import java.util.List;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

/**
 *
 * @author 杨帆
 * @version 1.0 2007 五月 29 14:29:49,创建
 */
public class IndexBuilder
{
	@SuppressWarnings("unused")
	private static final Log log = LogFactory.getLog(IndexBuilder.class);
	private List<IndexSource> indexSources = new ArrayList<IndexSource>();

	public void addIndexSources(IndexSource...indexSources)
	{
		for(IndexSource source : indexSources)
		{
			this.indexSources.add(source);
		}
	}

	public void buildIndex()
	{
		for(IndexSource indexSource : indexSources)
		{
			indexSource.buildIndex();
		}
	}
}
